﻿<%@ Page Language="C#" MasterPageFile="~/MasterPage.master" AutoEventWireup="true"
    CodeFile="Default.aspx.cs" Inherits="_Default" Title="欢迎进入EQT系统" %>

<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder" runat="Server">

    <script type="text/javascript">
        function InvokePop(url)
        {
            // to handle in IE 7.0          
            if (window.showModalDialog)
            {      
                retVal = window.showModalDialog(url ,'newwindow',"dialogHeight:500px;dialogWidth:800px;resizable:no;center:yes;");
            }
            // to handle in Firefox
            else
            {     
                retVal = window.open(url,'newwindow','height=500,width=600,resizable=yes,modal=yes');
            }  
            //window.location.href=window.location.pathname+"?co_item_id="+co_item_id;     
            return true;
        }
    </script>

    <h1 id="pagetitle" class="pagetitle">
        首页通知
    </h1>
    <asp:Panel ID="SummaryPanel" runat="server" Width="100%">
        <asp:Repeater ID="Repeater" runat="server">
            <HeaderTemplate>
                <table width="100%" border="0" cellspacing="0" cellpadding="0" align="left">
            </HeaderTemplate>
            <ItemTemplate>
                <tr style="height: 24px;">
                    <td style="width: 200px;">
                        <img src="images/bg_bullet_half_1.gif" alt="" />
                        <span style='color: <%# (DataBinder.Eval(Container.DataItem, "Rec_Status").ToString()=="0")?"red":"black"%>;'>
                            <%# DataBinder.Eval(Container.DataItem, "publish_type_name")%>
                            消息 &nbsp;&nbsp;&nbsp;&nbsp;发布日期：<%#string.Format("{0:yyyy-MM-dd}",DataBinder.Eval(Container.DataItem, "Create_Time"))%>
                        </span>
                    </td>
                    <td style="color: #757575;">
                        <%--                                    <a href="#" onclick="javascript:window.open ('noticedetail.aspx?RecID=<%#DataBinder.Eval(Container.DataItem, "Rec_ID")%>','newwindow','height=500,width=600,top=0,left=0,toolbar=no,menubar=no,scrollbars=yes, resizable=no,location=no, status=no')">
--%>
                        <a href="#" onclick="javascript:InvokePop('noticedetail.aspx?RecID=<%#DataBinder.Eval(Container.DataItem, "Rec_ID")%>')">
                            <%# this.Substring(DataBinder.Eval(Container.DataItem, "Title").ToString()) %>
                        </a>
                    </td>
                </tr>
            </ItemTemplate>
            <FooterTemplate>
                <tr style="height: 24px;">
                    <td colspan="2" align="right">
                        <a href="UsersNotice.aspx">查看更多通知...</a></td>
                </tr>
                </table>
            </FooterTemplate>
        </asp:Repeater>
    </asp:Panel>
</asp:Content>
